/*
 * BSM6.0
 *
 * Copyright 2012-2013 (C) SINODATA CO., LTD. All Rights Reserved.
 */
package snmptest.discover;

import java.net.InetAddress;

import org.opennms.netmgt.icmp.jni.JniPinger;

/**
 * <p>
 * Description: 
 * </p>
 *
 * @author wangyazhou
 * @version 1.0

 * <p>
 * History: 
 *
 * Date                     Author         Version     Description
 * ---------------------------------------------------------------------------------
 * 2013-8-21 下午2:23:35          wangyazhou        1.0         To create
 * </p>
 *
 * @since 
 * @see     
 */
public class OpenNmsPing {

    public static void main(String[] args) {
        try {
            JniPinger pinger = new JniPinger();
            Number rtt = pinger.ping(InetAddress.getByName("localhost"));

            System.out.println(rtt);
        } catch (Exception e) {
            e.printStackTrace();
        }
    }
}
